---
title: InferIntersectOutput
description: Infer intersect output type.
contributors:
  - fabian-hiller
---

# InferIntersectOutput

Infer intersect output type.

```ts
// Create object schemas
const ObjectSchemas = [
  v.object({
    key1: v.pipe(
      v.string(),
      v.transform((input) => input.length)
    ),
  }),
  v.object({
    key2: v.pipe(
      v.string(),
      v.transform((input) => input.length)
    ),
  }),
];

// Infer object intersect output type
type ObjectOutput = v.InferIntersectOutput<typeof ObjectSchemas>; // { key1: number } & { key2: number }
```
